<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
	<head>
		<meta http-equiv="content-type" content="text/html; charset=utf-8" />
		<meta name="description" content="" />
		<meta name="keywords" content="" />
		<meta name="author" content="" />
		<!-- Style Sheets (.css) -->
		<link rel="stylesheet" href="stylesheets/globalstyle.css" type="text/css" media="screen" />
		<link rel="stylesheet" href="menu.css" type="text/css" media="screen" />
		<link rel="stylesheet" href="front.css" media="screen, projection" type="text/css">
		<!-- end of Style Sheets -->
		<title>My Car Warehouse - for my search choices</title>
		<?
		session_start(); 
		include("includes/config.php");
		include("includes/login.php");
		?>
		<div id="header">
				<div id="login">
				   <? global $logged_in;
					if($logged_in){
						displayLogin(); 
					}
					else {
						include('includes/register.php'); 
						displayLogin();
						}
					?>
				</div> <!-- end #register & login -->
			<?php include('includes/header.php'); ?>
		</div> <!-- end #header -->
	</head>
	<script src="javascripts/jquery.js" type="text/javascript"></script>
	<script src="https://ajax.googleapis.com/ajax/libs/jquery/1.5.1/jquery.min.js"></script>
	<script src="javascripts/slides.min.jquery.js"></script>
	<script>
		$(function(){
			$('#slides').slides({
				preload: true,
				preloadImage: 'images/loading.gif',
				play: 5000,
				pause: 2500,
				hoverPause: true,
				animationStart: function(current){
					$('.caption').animate({
						bottom:-35
					},100);
					if (window.console && console.log) {
						// example return of current slide number
						console.log('animationStart on slide: ', current);
					};
				},
				animationComplete: function(current){
					$('.caption').animate({
						bottom:0
					},200);
					if (window.console && console.log) {
						// example return of current slide number
						console.log('animationComplete on slide: ', current);
					};
				},
				slidesLoaded: function() {
					$('.caption').animate({
						bottom:0
					},200);
				}
			});
		});
	</script>	
	<script type="text/javascript">
        $(document).ready(function() {
            $(".signin").click(function(e) {          
				e.preventDefault();
                $("fieldset#signin_menu").toggle();
				$(".signin").toggleClass("menu-open");
            });
			$("fieldset#signin_menu").mouseup(function() {
				return false
			});
			$(document).mouseup(function(e) {
				if($(e.target).parent("a.signin").length==0) {
					$(".signin").removeClass("menu-open");
					$("fieldset#signin_menu").hide();
				}
			});						
        });
	</script>
	<script type="text/javascript">
        $(document).ready(function() {
            $(".register").click(function(e) {          
				e.preventDefault();
                $("fieldset#register_menu").toggle();
				$(".register").toggleClass("menu-open");
            });
			$("fieldset#register_menu").mouseup(function() {
				return false
			});
			$(document).mouseup(function(e) {
				if($(e.target).parent("a.register").length==0) {
					$(".register").removeClass("menu-open");
					$("fieldset#register_menu").hide();
				}
			});						
        });
	</script>	
	<script src="javascripts/jquery.tipsy.js" type="text/javascript">
	</script>
	<script type='text/javascript'>
		$(function() {
		  $('#forgot_username_link').tipsy({gravity: 'w'});   
		});
	</script>
	<body> 
		<?php include('includes/menu.php'); ?> 
		<div id="wrapper">
			<div id="content">
				<?php include('includes/imageslide.php'); ?>
				<?php include('includes/posts.php'); ?>
			</div> <!-- end #content -->
			<div id="sidebar">
				<?php include('includes/simplesearch.php'); ?> 
				<?php include('includes/sidebar.php'); ?>
			</div><!-- end #sidebar -->
		</div> <!-- End #wrapper -->
		<div id="footer">
			<?php include('includes/footer.php'); ?>
		</div> <!-- end #footer -->
	</body>
</html>